/**
 *
 */
package cn.dw.dg.aop;

import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.annotation.After;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.ControllerAdvice;

/**
 * @author aubrey
 * @date  上午10:46:01
 * 
 */
@Component
@Aspect
public class LogAop {
	
//	@Pointcut("execution(* cn.dw.dg.controller.*.*(..))")
	
	@Pointcut("@annotation(cn.dw.dg.aop.Log)")
	public void pointCut() {};
	
	
	@Before("pointCut()")
	public void before(JoinPoint joinPoint) {
		System.out.println("-=========before===============");
	}
	
	@After("pointCut()")
	public void after() {
		System.out.println("-=========after===============");
	}
	
	
	
}
